<!DOCTYPE html>
<html>
<head>
    <script src="../build/react.js"></script>
    <script src="../build/react-dom.js"></script>
    <script src="../build/browser.min.js"></script>
</head>
<body>
<div id="example"></div>
<script type="text/babel">
    //      组件化
    class HelloMessage extends React.Component{
        render() {//复写方法
            return <div>Hello {this.props.name}</div>;
        }
    }
    ReactDOM.render(<HelloMessage name="world!"/>, document.getElementById("example"));

</script>
</body>
</html>

